package com.jj.service;

import com.jj.entity.Allocation;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

public interface AllocationService {
    @Transactional
    boolean addAllocation(Allocation allocation);
    @Transactional
    boolean updateAllocation(Allocation allocation);
    @Transactional
    boolean deleteAllocation(Long id);

    List<Allocation> selectCurrentAllocations(Long studentId);

    List<Allocation> selectAllocationHistoryByStudentId(Long studentId);

    List<Allocation> selectAllocationHistoryByDormitoryId(Long dormitoryId);

    List<Allocation> selectCurrentAllocationByStudentId(Long studentId);
}
